package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

/**
 * 采购车实体类
 */
@TableName("t_purchaseCar")
public class PurchaseCarBean {
     /**采购车编号*/
     @TableId(value = "pk_pId",type = IdType.AUTO)
     private Integer pcId;
     /**商品外键*/
     @TableField("fk_productId")
     private Integer productId;
     /**商品*/
     @TableField(exist = false)
     private ProductBean product;
     /**采购数量*/
     @TableField("p_num")
     private Integer num;
     /**采购价*/
     @TableField("p_price")
     private Integer tranPrice;
     /**采购人用户名*/
      @TableField("p_userName")
     private String userName;

     public PurchaseCarBean() {
     }

     public PurchaseCarBean(Integer productId, Integer num, String userName) {
          this.productId = productId;
          this.num = num;
          this.userName = userName;
     }

     public Integer getPcId() {
          return pcId;
     }

     public void setPcId(Integer pcId) {
          this.pcId = pcId;
     }

     public Integer getProductId() {
          return productId;
     }

     public void setProductId(Integer productId) {
          this.productId = productId;
     }

     public ProductBean getProduct() {
          return product;
     }

     public void setProduct(ProductBean product) {
          this.product = product;
     }

     public Integer getNum() {
          return num;
     }

     public void setNum(Integer num) {
          this.num = num;
     }

     public Integer getTranPrice() {
          return tranPrice;
     }

     public void setTranPrice(Integer tranPrice) {
          this.tranPrice = tranPrice;
     }

     public String getUserName() {
          return userName;
     }

     public void setUserName(String userName) {
          this.userName = userName;
     }

     @Override
     public String toString() {
          return "PurchaseCarBean{" +
                  "pcId=" + pcId +
                  ", productId=" + productId +
                  ", product=" + product +
                  ", num=" + num +
                  ", tranPrice=" + tranPrice +
                  ", userName='" + userName + '\'' +
                  "}\n";
     }
}
